<template>
	<view>
		<view style="width: 100%; background: #FFFFFF;">
			<view class="width-90" >
				<van-steps :steps="steps" :active=" active"  active-color="#53A4FC"/>
			</view>
		</view>
		
		<quick-register @getStep='getStep' v-if="active==0" ></quick-register>
		<input-validation-code @getStep='getStep'  v-if="active==1" :phoneNumber="phone"></input-validation-code>
		<set-password  v-if="active==2" :phoneData= "phoneData"></set-password>
	</view>
</template>

<script>
	import quickRegister from './quickRegister'
	import inputValidationCode from './inputValidationCode'
	import setPassword from './setPassword'
	export default {
		components:{
			quickRegister,
			inputValidationCode,
			setPassword
		},
		data() {
			return {
				steps: [{
						desc: '1.输入手机号'
					},
					{
						desc: '2.输入验证码'
					},
					{
						desc: '3.设置密码'
					}
				],
				active: 0,
				phone: '',
				phoneData: {}
			}
		},
		methods: {
			getStep:function(e){
				this.active = e.active
				this.phone = e.phoneNumber
				this.phoneData = e
			}
		}
	}
</script>

<style>

</style>
